/**
 * Host.java
 */
package dataTypes;

/**
 * Host descriptor
 * @author Michal Kolodziejski
 *
 */
public class Host {
	private String hostName;
	
	/**
	 * Constructor
	 */
	public Host() {
	}

	
	/**
	 * Copying constructor
	 * @param host
	 */
	public Host(Host host){
		if(host!=null)
			this.hostName = host.hostName;
	}
	
	/**
	 * @param hostName
	 */
	public Host(String hostName) {
		this.hostName = hostName;
	}

	/**
	 * @return the hostName
	 */
	public String getHostName() {
		return hostName;
	}

	/**
	 * @param hostName the hostName to set
	 */
	public void setHostName(String hostName) {
		this.hostName = hostName;
	}
	
	/**
	 * Overriden method
	 */
	public boolean equals(Object obj){
		if(obj == null)
			return false;
		if(!(obj instanceof Host))
			return false;
		Host objH = (Host)obj;
		if(!this.hostName.equals(objH.hostName))
			return false;
		return true;
	}
}
